package com.ag.bean;

import java.util.HashSet;
import java.util.Set;
import javax.persistence.CascadeType;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.FetchType;
import javax.persistence.Id;
import javax.persistence.OneToMany;
import javax.persistence.Table;

/**
 * TbExpertArea entity.
 * 
 * @author MyEclipse Persistence Tools
 */
@Entity
@Table(name = "TB_EXPERT_AREA", schema = "dbo", catalog = "AGDB")
public class TbExpertArea implements java.io.Serializable {

	// Fields

	private String expareaId;
	private String expareaName;
	private String a;
	private String b;
	private String c;
	private Set<TbExpert> tbExperts = new HashSet<TbExpert>(0);

	// Constructors

	/** default constructor */
	public TbExpertArea() {
	}

	/** minimal constructor */
	public TbExpertArea(String expareaId, String expareaName) {
		this.expareaId = expareaId;
		this.expareaName = expareaName;
	}

	/** full constructor */
	public TbExpertArea(String expareaId, String expareaName, String a,
			String b, String c, Set<TbExpert> tbExperts) {
		this.expareaId = expareaId;
		this.expareaName = expareaName;
		this.a = a;
		this.b = b;
		this.c = c;
		this.tbExperts = tbExperts;
	}

	// Property accessors
	@Id
	@Column(name = "EXPAREA_ID", unique = true, nullable = false, length = 4)
	public String getExpareaId() {
		return this.expareaId;
	}

	public void setExpareaId(String expareaId) {
		this.expareaId = expareaId;
	}

	@Column(name = "EXPAREA_NAME", nullable = false, length = 100)
	public String getExpareaName() {
		return this.expareaName;
	}

	public void setExpareaName(String expareaName) {
		this.expareaName = expareaName;
	}

	@Column(name = "A", length = 50)
	public String getA() {
		return this.a;
	}

	public void setA(String a) {
		this.a = a;
	}

	@Column(name = "B", length = 50)
	public String getB() {
		return this.b;
	}

	public void setB(String b) {
		this.b = b;
	}

	@Column(name = "C", length = 50)
	public String getC() {
		return this.c;
	}

	public void setC(String c) {
		this.c = c;
	}

	@OneToMany(cascade = CascadeType.ALL, fetch = FetchType.LAZY, mappedBy = "tbExpertArea")
	public Set<TbExpert> getTbExperts() {
		return this.tbExperts;
	}

	public void setTbExperts(Set<TbExpert> tbExperts) {
		this.tbExperts = tbExperts;
	}

}